home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2009 February / PCWFEB09.iso / Software / Linux / Kubuntu 8.10 / kubuntu-8.10-desktop-i386.iso / casper / filesystem.squashfs / var / lib / dpkg / info / base-passwd.prerm < prev    next >
Text File  |  2007-11-17  |  466b  |  30 lines

  1. #! /bin/sh
  2.  
  3. set -e
  4.  
  5. # A cut-down version of 'which' from debianutils.
  6. searchpath () {
  7.     PROGRAM="$1"
  8.     IFS_SAVE="$IFS"
  9.     IFS=:
  10.     RET=1
  11.     for ELEMENT in $PATH; do
  12.         if [ -z "$ELEMENT" ]; then
  13.             ELEMENT=.
  14.         fi
  15.         if [ -f "$ELEMENT/$PROGRAM" ] && \
  16.            [ -x "$ELEMENT/$PROGRAM" ]; then
  17.             RET=0
  18.             break
  19.         fi
  20.     done
  21.     IFS="$IFS_SAVE"
  22.     return "$RET"
  23. }
  24.  
  25. if ([ "$1" = remove ] || [ "$1" = upgrade ]) && searchpath install-docs; then
  26.     install-docs -r users-and-groups
  27. fi
  28.  
  29. exit 0
  30.